<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>7.2.1 P72 动态数据</title>
</head>
<body>
<div id="app">
    <my-component message="[1,2,3,4]"></my-component>
    <my-component :message="[1,2,3]"></my-component>
</div>
<script src="https://cdn.jsdelivr.net/npm/vue"></script>
<script>
    Vue.component('my-component',{
        props:['message'],
        template:'<div>{{message.length}}</div>'
    });
    var app = new Vue({
        el:'#app'
    })
</script>
</body>
</html>